﻿<UserControl
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d"
    xmlns:local="clr-namespace:MySilverlightAlbum"
    x:Class="MySilverlightAlbum.MainMenu"
    d:DesignWidth="640"
    d:DesignHeight="480">

    <Grid
        VerticalAlignment="Stretch"
        HorizontalAlignment="Stretch">

        <Grid.ColumnDefinitions>
            <ColumnDefinition
                Width="210" />
            <ColumnDefinition
                Width="*" />
            <ColumnDefinition
                Width="150" />
        </Grid.ColumnDefinitions>

        <Rectangle
            Grid.Column="0"
            Grid.ColumnSpan="3"
            VerticalAlignment="Stretch"
            HorizontalAlignment="Stretch"
            Fill="{StaticResource MenuFill}" />

        <TextBlock
            Grid.Column="0"
            HorizontalAlignment="Left"
            Margin="2,-2,0,0"
            VerticalAlignment="Top"
            Width="200"
            FontFamily="Arial Black"
            FontSize="16"
            FontStyle="Italic"
            FontWeight="Bold"
            Foreground="#FFDC7A4A"
            Text="{Binding Title, Mode=OneWay}"
            TextWrapping="Wrap">
        	<TextBlock.Effect>
        		<DropShadowEffect
                    BlurRadius="2"
                    Direction="350"
                    ShadowDepth="1" />
        	</TextBlock.Effect>
        </TextBlock>

        <StackPanel
            Grid.Column="1"
            VerticalAlignment="Stretch"
            HorizontalAlignment="Stretch"
            Orientation="Horizontal">

            <ItemsControl
                x:Name="menuItems">

                <ItemsControl.ItemsPanel>
                    <ItemsPanelTemplate>
                        <StackPanel
                            Orientation="Horizontal" />
                    </ItemsPanelTemplate>
                </ItemsControl.ItemsPanel>

                <ItemsControl.ItemTemplate>
                    <DataTemplate>
                        <local:ToolbarMenuItem
                            x:Name="{Binding Id, Mode=OneTime}"
                            Title="{Binding Title, Mode=OneWay}"
                            Description="{Binding Description, Mode=OneWay}"
                            Width="110"
                            FontWeight="Bold"
                            IsTabStop="False"
                            MoreMark=" >>"
                            Separator="0 0 1 0"
                            Click="OnMenuClick"
                            Margin="1" />
                    </DataTemplate>
                </ItemsControl.ItemTemplate>
            </ItemsControl>

            <local:ToolbarMenuItem
                x:Name="contact"
                Title="CONTACT"
                FontWeight="Bold"
                Description="contact me"
                IsTabStop="False"
                Width="70"
                Click="OnMenuClick"
                Separator="0 0 0 0"
                Margin="1" />

        </StackPanel>

        <StackPanel
            Grid.Column="2"
            VerticalAlignment="Stretch"
            HorizontalAlignment="Stretch"
            Orientation="Horizontal">

            <local:ToolbarMenuItem
                x:Name="fullscreen"
                Title="full screen"
                FontWeight="Normal"
                Description="also Esc key"
                IsTabStop="False"
                Width="70"
                Click="OnMenuClick"
                Separator="0 0 1 0"
                Margin="1" />

            <local:ToolbarMenuItem
                x:Name="togglemenu"
                Title="toggle menu"
                FontWeight="Normal"
                Description="also Enter key"
                IsTabStop="False"
                Width="80"
                Click="OnMenuClick"
                Separator="0 0 0 0"
                Margin="1" />

        </StackPanel>

    </Grid>
</UserControl>
